export default {
	//用户taken 
	token: false,
	//用户信息
	userinfo: false,
	//权限验证跳转
	navigate(option,type = "navigateTo") {
		//是否登录验证
		 if(!this.token){
			  return  uni.navigateTo({
			 	url: '/pages/login/login',
			 });
		 }

		//跳转
		switch (type) {
			case 'navigateTo':
				uni.navigateTo({
					url: 'option',
				});
				break;
			case "redirectTo":
				uni.redirectTo(options);
				break;
			case "reLaunch":
				uni.reLaunch(options);
				break;
			case "switchTab":
				uni.switchTab(options);
				break;

		}
	}
}
